Skip to content

fix: clean up properly shared modal page router outlets #1360

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 12, 2018

Conversation

manoldonev
Copy link
Contributor

Fix named page router outlets cleanup to enable scenarios where modal dialog is "shared" i.e. it is attached to the root viewContainerRef and can be opened from different host components without the need to define specific child route for each host component.

Fixes #340

@manoldonev manoldonev self-assigned this Jun 1, 2018
@ghost ghost added the in progress label Jun 1, 2018
vakrilov
vakrilov previously approved these changes Jun 5, 2018
this.currentUrlTree.root.children[this.currentOutlet] = state.segmentGroup;
if (state) {
this.currentUrlTree.root.children[this.currentOutlet] = state.segmentGroup;
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggestion: add a comment on when state comes in as undefined and why the cleanup logic is needed.

@manoldonev manoldonev force-pushed the mdonev/outlet-cleanup-fix branch 3 times, most recently from 3b3cd3d to 6e7c051 Compare June 7, 2018 11:15
@manoldonev manoldonev force-pushed the mdonev/outlet-cleanup-fix branch from 6e7c051 to 8345daa Compare June 7, 2018 11:20
@jolafrite
Copy link

Hi guys,
is this will be merged soon ?

@manoldonev
Copy link
Contributor Author

@jolafrite as soon as the tests pass.

@manoldonev manoldonev merged commit 3332ca2 into master Jun 12, 2018
@ghost ghost removed the in progress label Jun 12, 2018
@manoldonev manoldonev deleted the mdonev/outlet-cleanup-fix branch June 12, 2018 07:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants